let DEBUG = true;
let postMessageKey = "";

function yRegisterPlugin(in_DEBUG, inPostMessageKey) {
    DEBUG = (in_DEBUG === "1");
    postMessageKey = inPostMessageKey;
}

function yRunFlutter(page, method, params = {}) {
    window.postMessage(`${postMessageKey}_${JSON.stringify({"page": page, "method": method, "params": params})}`, "*");
}